<template>
  <div>
    <h1 @click="ckickPP">我是自定义组件</h1>
    <h2>{{ subData }}</h2>
  </div>
</template>

<script>
export default {
  props: ["subData"],
  methods: {
    ckickPP() {
      alert("我可以触发");
    },
  },

  mounted() {
    console.log(this.subData);
  },
};
</script>

<style></style>
